package com.cloudptt.wp.ui.address;

import android.app.Activity;
import android.os.Bundle;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnTouchListener;
import android.widget.TextView;

import com.cloudptt.wp.R;
import com.mcptt.db.model.UserInfo;

public class AddressDetailActivity extends Activity {
	
	private TextView backView;
	private TextView userNameView;
	private TextView userNumView;
//	private static final String THIS_FILE = "UserInfo";
	
	
	public void onCreate(Bundle savedInstanceState) {

		super.onCreate(savedInstanceState);
		
		setContentView(R.layout.user_info_view);	
		
        initView();		
        
//        SysApplication app = ((SysApplication) getApplicationContext());
//		app.addClearActivity(this);
	}
	
	
	


	private void initView() {		
		
		UserInfo userinfo = (UserInfo) getIntent().getSerializableExtra("userinfo");		
		
		userNameView = (TextView)findViewById(R.id.user_info_name);		
		userNumView = (TextView)findViewById(R.id.user_info_num);
		
		userNameView.setText(userinfo.getName());
		userNumView.setText(userinfo.getAddrId());
		
		backView = (TextView)findViewById(R.id.cancel);
		
		backView.setOnTouchListener(new OnTouchListener() {		
			
			@Override
			public boolean onTouch(View v, MotionEvent event) {

				finish();
				return false;
			}
		});
				
		
	}

}
